package com.vdong.ai.http;

import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

@FeignClient(url = "https://api.xfyun.cn", name = "postKeDaXunFeiServiceHttpClient", configuration = FeignConfiguration.class)
public interface PostKeDaXunFeiServiceHttpClient {

    @RequestMapping(value = "/v1/aiui/v1/iat", method = RequestMethod.POST, consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE
    )
    String AiVoice(@RequestBody String fileData, @RequestHeader("X-Appid") String appid, @RequestHeader("X-CurTime") String curTime, @RequestHeader("X-Param") String param, @RequestHeader("X-CheckSum") String checkSum, @RequestHeader("Connection") String connection);

}